// 导航条的外部容器
.top-bar{
    height: 48px;
    background-color: #000;
    padding: 0 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
a{
    color: #fff;
    &:hover{
        color: rgb(197, 196, 196);
    }
}
//左侧
.left{
    &:hover{
        .nav{
            display: block;
        }
    }
    // position: relative;
    //设置菜单
    .nav{
        display: none;
        position: absolute;
        top: 48px;
        left: 0;
        bottom: 0;
        right: 0;
        background-color: black;
        padding-top: 50px;
        transition: 0.3s;
        
        li{
            width: 80%;
            height: 44px;
            margin: 0 auto;
            a{
                line-height: 44px;
                display: block;
                font-size: 14px;
                border-bottom: 1px solid #757474;
            }
        }
        li:last-child{
            display: flex;
            justify-content: center;
            a{
                border-bottom: none;
                padding: 10px;
                i{
                    padding: 5px;
                }
            }
        }
    }
    .menu-icon{
        width: 18px;
        height: 48px;
        position: relative;

        li{
            width: 18px;
            height: 1px;
            background-color: #ffffff;
            position: absolute;
            transform-origin: left center;
            transition: 0.3s;
        }
        
        li:nth-child(1){
            top: 18px;
        }
        li:nth-child(2){
            top: 24px;
        }
        li:nth-child(3){
            top: 30px;
        }
        //鼠标移动效果  应该用js实现
        &:hover{
            li:nth-child(1){
                //向下旋转
                transform: rotateZ(45deg);
            }
            li:nth-child(2){
                //隐藏
                visibility: hidden;
            }
            li:nth-child(3){
                //向上旋转
                transform: rotateZ(-45deg);
            }
        }
    }
}
//中间logo
.logo{
    img{
        width: 73px;
        height: 20px;
    }
}


//设置媒体查询
@media only screen {
    @media (min-width: 760px){
        .left{
            &:hover{
                .nav{
                    display: flex;
                }
            }
            order: 2;
            //隐藏菜单图标
            .menu-icon{display: none;}
            //显示菜单
            .nav{
                display: flex;
                position: static;
                padding: 0;
                li{
                    width: auto;
                    border-bottom: none;
                    padding: 0 20px;
                    a{
                        line-height: 48px;
                        border: none;
                    }
                }
                li:last-child{
                    margin-left: 100px;
                    a{
                        padding: 0;
                        i{
                            padding: 0;
                        }
                    }
                }
            }
        }
        .logo{
            order: 1;
        }
        div{order: 3;}
    }
}